package com.zjj.algorithm.learning.niuke;

import java.util.Arrays;
import java.util.Scanner;

/**
 * @author zjj_admin
 * @date 2023/2/8 20:53
 */
public class Test3 {

    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int len = in.nextInt();
        int[] nums = new int[len];
        int i = 0;
        while (i < len) {
            nums[i] = in.nextInt();
            i++;
        }
        Arrays.sort(nums);
        int len1 = 1;
        for (int j = 1; j < nums.length; j++) {
            if(nums[j] != nums[j - 1]){
                len1 ++;
            }
        }
        int[] nums1 = new int[len1];
        nums1[0] = nums[0];
        int index = 0;
        for (int j = 1; j < nums.length; j++) {
            if(nums[j] != nums[j - 1]){
                nums1[++index] = nums[j];
            }
        }
        for (int num : nums1) {
            System.out.println(num);
        }
    }
}
